package com.code.day16.c_thread;

public class Product implements Runnable{
    private BaoZiPu bzp;
    public Product(BaoZiPu bzp) {
        this.bzp = bzp;
    }

    @Override
    public void run() {

        while(true) {

            try {
                Thread.sleep(100l);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }

            bzp.setCount();

        }

    }
}
